<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <style>
      .one{
        color: red;
      }
      .two{
        color: blue;
        font-size: 14px;
        /* fontSize */
      }
    </style>
    <title>Document</title>
  </head>
  <body>
    <div id="app">{{ msg }}
      <div :class="userId %2===1?'one':'two' ">
          abcd 
      </div>

    </div>
  </body>
</html>
<script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
<script> 
  const app = Vue.createApp({
    
    data() { //  定义对象的属性
      return {
        msg: "hello",
        userId:1
      };
    },
  });
  app.mount("#app");
</script>
